<?php
header ("Content-Type:text/xml");
require_once '../config.php';

echo '<?xml version="1.0" encoding="utf-8"?>';
echo '<resources>';
echo '<string-array name="courses">';

$query = "SELECT * FROM courses ORDER BY code ASC;";
$result = mysqli_query($db, $query);
while($row = mysqli_fetch_assoc($result)){
    echo '<item>'.str_replace("&", "und", $row['name_de']).'</item>';
}
echo '</string-array>';
echo '</resources>';
?>
